﻿using Credera.Theta.API;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Credera.Theta.Modules.Environments.Commands
{
    [Command("OpenEnvironmentsFile")]
    [Synopsis("Opens the environments file in the default XML editor")]
    class OpenEnvironmentsFileCommand : InputCommand
    {
        public override void Invoke(CommandInvocationContext context)
        {
            Process.Start(new ProcessStartInfo(EnvironmentLogic.FILE_PATH_ENVIRONMENTS));
            base.Out.Warning.WriteLine("Any changes made to the environments file will require a restart of the application to take effect. Also, any updates made to the environments from within the application may overwrite your changes.");
        }
    }
}
